{extends file='layout/main.html'}
{block name="main"}

<div class="main_title">
	<h2>email列表</h2>
	<p>email列表及管理用户</p>
</div>

<div class="btn_blk">
	<div class="fr">
		<a href="#" class="btn2 fr ml20 del_all">删除</a>
	</div>
</div>
<form action="?url=artist/email_delete" method="post" accept-charset="utf-8" id="res_del">

<table width="100%" class="table_list">
	<tr>
		<th width="55"><input type="checkbox" class="checkAll" rel="check[]"/></th>
		<th>艺术家</th>
		<th>email</th>
		<th width="80">操作</th>
	</tr>
	{foreach $data as $val}
	<tr{if $val@iteration % 2} class="odd"{/if}>
		<td><input type="checkbox" name="check[]" value="{$val.id}"></td>
		<td>{$name.name}</td>
		<td>{$val.email}</td>
		<td class="tc">
			<a href="?url=artist/email_delete&id={$val.id}" class="delete"><img src="{gen_theme_url('images/i.gif')}" class="ico_del" title="删除"></a>
		</td>
	</tr>
	{/foreach}

</table>
</form>
<div class="btn_blk">
	<div class="fr">
		<a href="#" class="btn2 fr ml20 del_all">删除</a>
		{include file="lib/pager.html"}
	</div>

</div>
<script type="text/javascript" charset="utf-8">
$('.del_all').click(function(){
	var check = $(":checkbox:checked").size();
	if (!check) {
		alert('你还没有选择要删除的用户');
		return false;
	};
	$("#res_del").submit();
  return false;
});
</script>
{/block}
